// pages/coach_list/coach_list.js
const app = getApp()
Page({

  data: {
    coach:[]
  },
  onLoad: function (options) {
    let that = this
    wx.request({
      url: app.url + 'weiapp/api/coachs',
      data: {},
      success: function (res) {
        console.log(res.data)
        that.setData({
          coach: res.data,
        })
      }
    })
  },
  goCoachGoods(even){
    wx.navigateTo({
      url: '../coach_goods/coach_goods?id=' + even.currentTarget.dataset.id,
    })
  }
})